import service from '@/utils/request'
// @Tags A商品
// @Summary 创建商品
// @Security ApiKeyAuth
// @accept application/json
// @Produce application/json
// @Param data body model.A商品 true "创建商品"
// @Success 200 {string} string "{"success":true,"data":{},"msg":"创建成功"}"
// @Router /shangpin/createA商品 [post]
export const createA商品 = (data) => {
  return service({
    url: '/shangpin/createA商品',
    method: 'post',
    data
  })
}

// @Tags A商品
// @Summary 删除商品
// @Security ApiKeyAuth
// @accept application/json
// @Produce application/json
// @Param data body model.A商品 true "删除商品"
// @Success 200 {string} string "{"success":true,"data":{},"msg":"删除成功"}"
// @Router /shangpin/deleteA商品 [delete]
export const deleteA商品 = (params) => {
  return service({
    url: '/shangpin/deleteA商品',
    method: 'delete',
    params
  })
}

// @Tags A商品
// @Summary 批量删除商品
// @Security ApiKeyAuth
// @accept application/json
// @Produce application/json
// @Param data body request.IdsReq true "批量删除商品"
// @Success 200 {string} string "{"success":true,"data":{},"msg":"删除成功"}"
// @Router /shangpin/deleteA商品 [delete]
export const deleteA商品ByIds = (params) => {
  return service({
    url: '/shangpin/deleteA商品ByIds',
    method: 'delete',
    params
  })
}

// @Tags A商品
// @Summary 更新商品
// @Security ApiKeyAuth
// @accept application/json
// @Produce application/json
// @Param data body model.A商品 true "更新商品"
// @Success 200 {string} string "{"success":true,"data":{},"msg":"更新成功"}"
// @Router /shangpin/updateA商品 [put]
export const updateA商品 = (data) => {
  return service({
    url: '/shangpin/updateA商品',
    method: 'put',
    data
  })
}

// @Tags A商品
// @Summary 用id查询商品
// @Security ApiKeyAuth
// @accept application/json
// @Produce application/json
// @Param data query model.A商品 true "用id查询商品"
// @Success 200 {string} string "{"success":true,"data":{},"msg":"查询成功"}"
// @Router /shangpin/findA商品 [get]
export const findA商品 = (params) => {
  return service({
    url: '/shangpin/findA商品',
    method: 'get',
    params
  })
}

// @Tags A商品
// @Summary 分页获取商品列表
// @Security ApiKeyAuth
// @accept application/json
// @Produce application/json
// @Param data query request.PageInfo true "分页获取商品列表"
// @Success 200 {string} string "{"success":true,"data":{},"msg":"获取成功"}"
// @Router /shangpin/getA商品List [get]
export const getA商品List = (params) => {
  return service({
    url: '/shangpin/getA商品List',
    method: 'get',
    params
  })
}
// @Tags A商品
// @Summary 获取数据源
// @Security ApiKeyAuth
// @accept application/json
// @Produce application/json
// @Success 200 {string} string "{"success":true,"data":{},"msg":"查询成功"}"
// @Router /shangpin/findA商品DataSource [get]
export const getA商品DataSource = () => {
  return service({
    url: '/shangpin/getA商品DataSource',
    method: 'get',
  })
}
// @Tags A商品
// @Summary 不需要鉴权的商品接口
// @accept application/json
// @Produce application/json
// @Param data query request.A商品Search true "分页获取商品列表"
// @Success 200 {object} response.Response{data=object,msg=string} "获取成功"
// @Router /shangpin/getA商品Public [get]
export const getA商品Public = () => {
  return service({
    url: '/shangpin/getA商品Public',
    method: 'get',
  })
}